package com.tobby.camelinaction.scalability;

import org.apache.camel.Component;
import org.apache.camel.Consumer;
import org.apache.camel.Processor;
import org.apache.camel.Producer;
import org.apache.camel.impl.DefaultEndpoint;

public class ErpEndpoint extends DefaultEndpoint {

	public ErpEndpoint(String uri, Component component) {
		super(uri, component);
	}

	@Override
	public Producer createProducer() throws Exception {
		return new ErpProducer(this);
	}

	@Override
	public Consumer createConsumer(Processor processor) throws Exception {
		throw new UnsupportedOperationException("ErpComponent does not support consumer");
	}

	@Override
	public boolean isSingleton() {
		return true;
	}

}
